package gui;

import java.awt.BorderLayout;
import java.awt.EventQueue;
import java.awt.Graphics;

import javax.swing.JFrame;
import javax.swing.JPanel;
import javax.swing.border.EmptyBorder;
import javax.swing.JLabel;
import javax.swing.JTextField;
import javax.swing.JComboBox;
import javax.swing.JCheckBox;
import javax.swing.SwingConstants;

import java.awt.Component;
import java.awt.event.WindowAdapter;
import java.awt.event.WindowEvent;

import javax.swing.JButton;
import java.awt.event.ActionListener;
import java.awt.event.ActionEvent;

public class UsuarioPerfil extends JFrame {

	private JPanel contentPane;
	private JTextField textField;
	private JLabel lblNombreDeUsuario;
	private JTextField textField_2;
	private JTextField textField_3;
	private JTextField textField_4;
	private JLabel lblTelefono;
	private JLabel lblApellido;
	private JLabel lblNombre;
	private JLabel lblDomicilio;
	private JTextField textField_1;
	private JTextField textField_5;
	private JTextField textField_6;
	private JTextField textField_7;
	private JLabel lblTelefonoAdicional;
	private JLabel lblMail;
	private JLabel lblDni;
	private JLabel lblPerfil;
	private JComboBox comboBox;
	private JCheckBox chckbxNewCheckBox;
	private JButton btnNewButton;
	private JButton btnGuardarCambios;

	/**
	 * Launch the application.
	 */
	/*public static void main(String[] args) {
		EventQueue.invokeLater(new Runnable() {
			public void run() {
				try {
					UsuarioPerfil frame = new UsuarioPerfil();
					frame.setVisible(true);
				} catch (Exception e) {
					e.printStackTrace();
				}
			}
		});
	}

	/**
	 * Create the frame.
	 */
	public UsuarioPerfil(Principal padre) {
		addWindowListener(new WindowAdapter() {
			public void windowClosing(WindowEvent e){
				padre.nullusuariosperfil();
			}
		});
		setTitle("Perfil de Usuario");
		setDefaultCloseOperation(JFrame.DISPOSE_ON_CLOSE);
		setBounds(115, 115, 370, 343);
		contentPane = new JPanel();
		contentPane.setBorder(new EmptyBorder(5, 5, 5, 5));
		setContentPane(contentPane);
		contentPane.setLayout(null);
		
		textField = new JTextField();
		textField.setColumns(10);
		textField.setBounds(129, 11, 210, 20);
		contentPane.add(textField);
		
		textField_1 = new JTextField();
		textField_1.setColumns(10);
		textField_1.setBounds(129, 187, 210, 20);
		contentPane.add(textField_1);
		
		textField_2 = new JTextField();
		textField_2.setEditable(false);
		textField_2.setColumns(10);
		textField_2.setBounds(129, 36, 210, 20);
		contentPane.add(textField_2);
		
		textField_3 = new JTextField();
		textField_3.setEditable(false);
		textField_3.setColumns(10);
		textField_3.setBounds(129, 61, 210, 20);
		contentPane.add(textField_3);
		
		textField_4 = new JTextField();
		textField_4.setColumns(10);
		textField_4.setBounds(129, 86, 210, 20);
		contentPane.add(textField_4);
		
		textField_5 = new JTextField();
		textField_5.setEditable(false);
		textField_5.setColumns(10);
		textField_5.setBounds(129, 162, 210, 20);
		contentPane.add(textField_5);
		
		textField_6 = new JTextField();
		textField_6.setColumns(10);
		textField_6.setBounds(129, 137, 210, 20);
		contentPane.add(textField_6);
		
		textField_7 = new JTextField();
		textField_7.setColumns(10);
		textField_7.setBounds(129, 112, 210, 20);
		contentPane.add(textField_7);
		
		lblNombreDeUsuario = new JLabel("Nombre de Usuario:");
		lblNombreDeUsuario.setBounds(10, 14, 109, 14);
		contentPane.add(lblNombreDeUsuario);
		
		lblTelefono = new JLabel("Telefono:");
		lblTelefono.setBounds(10, 89, 109, 14);
		contentPane.add(lblTelefono);
		
		lblApellido = new JLabel("Apellido:");
		lblApellido.setBounds(10, 64, 109, 14);
		contentPane.add(lblApellido);
		
		lblNombre = new JLabel("Nombre:");
		lblNombre.setBounds(10, 39, 109, 14);
		contentPane.add(lblNombre);
		
		lblDomicilio = new JLabel("Domicilio:");
		lblDomicilio.setBounds(10, 190, 109, 14);
		contentPane.add(lblDomicilio);
		
		lblTelefonoAdicional = new JLabel("Telefono Adicional:");
		lblTelefonoAdicional.setBounds(10, 115, 109, 14);
		contentPane.add(lblTelefonoAdicional);
		
		lblMail = new JLabel("Mail:");
		lblMail.setBounds(10, 140, 109, 14);
		contentPane.add(lblMail);
		
		lblDni = new JLabel("DNI:");
		lblDni.setBounds(10, 165, 109, 14);
		contentPane.add(lblDni);
		
		lblPerfil = new JLabel("Perfil:");
		lblPerfil.setBounds(10, 215, 109, 14);
		contentPane.add(lblPerfil);
		
		comboBox = new JComboBox();
		comboBox.setEditable(true);
		comboBox.setBounds(129, 212, 210, 20);
		comboBox.setEnabled(false);
		contentPane.add(comboBox);
		
		chckbxNewCheckBox = new JCheckBox("Activo");
		chckbxNewCheckBox.setHorizontalAlignment(SwingConstants.RIGHT);
		chckbxNewCheckBox.setHorizontalTextPosition(SwingConstants.LEFT);
		chckbxNewCheckBox.setBounds(242, 239, 97, 23);
		contentPane.add(chckbxNewCheckBox);
		
		btnNewButton = new JButton("Cancelar");
		btnNewButton.addActionListener(new ActionListener() {
			public void actionPerformed(ActionEvent e) {
				padre.nullusuariosperfil();
				dispose();
			}
		});
		btnNewButton.setBounds(193, 269, 146, 23);
		contentPane.add(btnNewButton);
		
		btnGuardarCambios = new JButton("Guardar Cambios");
		btnGuardarCambios.setBounds(10, 269, 146, 23);
		contentPane.add(btnGuardarCambios);
	}

}